package com.buba.springcloud.controller;

import com.buba.springcloud.config.ConfigData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author：xy
 */
@RestController
public class ConfigClientController {

    @Autowired
    private ConfigData configData;

//    @Value("${config.info}")
//    private String configInfo;

    @GetMapping("/configInfo")
    private String getConfigInfo() {
        return configData.getConfigInfo();
    }
}
